package com.demo.boot.rest;

import com.demo.boot.entity.Student;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author ccubee
 * @since 21-4-19 20:35
 */
@RestController
@RequestMapping("demo")
public class DemoRest {


//    @Value("${server.port}")
//    String port;

    @GetMapping("port")
    public String port() {
        return "1231";
    }


    @GetMapping("student")
    public String port(Student student, @RequestParam Integer id) {
        System.out.println(student);
        System.out.println(id);
        return "1231";
    }



}
